Skip to main content
Version: 4.x.x

CacheAsyncStorageType


import { CacheAsyncStorageType } from "@hyper-fetch/core"

Description

Defined in cache/cache.types.ts:49

Preview

type CacheAsyncStorageType = {
delete: (key: string) => Promise<void>;
get: <Response,Error,Adapter>(key: string) => Promise<CacheValueType<Response, Error, Adapter> | undefined>;
keys: () => Promise<string[] | IterableIterator<string> | string[]>;
set: <Response,Error,Adapter>(key: string, data: CacheValueType<Response, Error, Adapter>) => Promise<void>;
}

Structure

{
delete: (key: string) => Promise<void>;
get: (key: string) => Promise<CacheValueType<Response, Error, Adapter> | undefined>;
keys: () => Promise<string[] | IterableIterator<string> | string[]>;
set: (key: string, data: CacheValueType<Response, Error, Adapter>) => Promise<void>;
}